# frozen_string_literal: true

FactoryBot.define do
  factory :formula, class: Formula::Mrb.name do
    type { Formula::Mrb }
    content { '1 + 1' }
    association :formulable, factory: :rule_output_dsl

    # formulable
    factory :formula_rule_entity_dsl do
      association :formulable, factory: :rule_entity_general_rule_dsl
    end
    factory :formula_rule_entity_condition_dsl do
      association :formulable, factory: :rule_entity_general_rule_condition_dsl
    end
    factory :formula_rule_output do
      association :formulable, factory: :rule_output_dsl
    end

    # factory
    factory :formula_mrb do
      type { Formula::Mrb }
      # formulable
    end
  end
end
